<?php
/**
 *
 * @author Lukas Normantas
 */
class Default_Model_UserPasswordChange extends Doctrine_Record
{

    public function setTableDefinition()
    {
        $this->setTableName('user_password_changes');
        $this->hasColumn('code', 'string', 32);
        $this->hasColumn('user_id', 'integer');
    }

    public function setUp()
    {
        $this->actAs('Timestampable');

        $this->hasOne('Default_Model_User as User', array(
                'local' => 'user_id',
                'foreign' => 'id'
            ));
    }

}
